<template>
    <div class="addProject business-workAdd">
        <div class="addForm zll-form">
            <div class="tableList">
                <table border="1">
                    <tr>															
                        <th>年度</th>
                        <th>发电量（MWh）</th>
                        <th>CO2减排（吨）</th>
                        <th>等效绿植（棵）</th>
                        <th>自用电量（MWh）</th>
                        <th>余电电量（MWh）</th>
                        <th>自用率</th>
                        <th>发电最高月</th>
                        <th>发电最高日</th>
                    </tr>
                    <tr class="add_Table">
                        <td><el-input v-model="addForm.recordYear" placeholder="" class="text_center" clearable disabled></el-input></td>
                        <td><el-input v-model="addForm.powerGeneration" placeholder="" class="text_center" clearable :disabled="type == 'see'"></el-input></td>
                        <td><el-input v-model="addForm.co2" placeholder="" class="text_center" clearable :disabled="type == 'see'"></el-input></td>
                        <td><el-input v-model="addForm.equivalentPlant" placeholder="" class="text_center" clearable :disabled="type == 'see'"></el-input></td>
                        <td><el-input v-model="addForm.selfConsumption" placeholder="" class="text_center" clearable :disabled="type == 'see'"></el-input></td>
                        <td><el-input v-model="addForm.powerSurplus" placeholder="" class="text_center" clearable :disabled="type == 'see'"></el-input></td>
                        <td><el-input v-model="addForm.selfUseRate" placeholder="" class="text_center" clearable :disabled="type == 'see'"></el-input></td>
                        <td><el-input v-model="addForm.maxGenerateMonths" placeholder="" class="text_center" clearable :disabled="type == 'see'"></el-input></td>
                        <td><el-input v-model="addForm.maxGenerateDays" placeholder="" class="text_center" clearable :disabled="type == 'see'"></el-input></td>
                    </tr>
                </table>
            </div>
        </div>
  </div>
</template>

<script>
export default {
	props: ['editData','type'],
    data(){
        return {
            addForm: {
				recordYear:'',
				powerGeneration:'',
				co2:'',
				equivalentPlant:'',
				selfConsumption:'',
				powerSurplus:'',
				selfUseRate:'',
				maxGenerateMonths:'',
				maxGenerateDays:'',
            },

        }
    },
    methods: {

    },

	watch: {
    	editData(val) {

    		this.addForm = {};
    		if (Object.getOwnPropertyNames(val).length > 1){
    			this.addForm = Object.assign({},val);
			}
		}
	}
}
</script>

<style lang="scss" scoped>
    @import "@/style/dialog.scss";
</style>